// JavaScript Document
var error = "";
				var ordDate="";
				
function validateForm2(strURL,formname,responsediv,responsemsg) {
				error = "";
				var _boolForm = 0;
				var emptyPreMessge = "You must include an accurate";
				var emptyPostMessge = "for a response";
				ordDate=document.forms["frmOrders"]["txtOrderDate"].value;
				document.getElementById("status").innerHTML	= "";
				var nameError = "";
				if(ordDate == "" || ordDate == null)
				{
					document.forms["frmOrders"]["txtOrderDate"].focus();
					error = "Date must not be empty";
					document.getElementById("status").innerHTML	= error;
					//alert(error);	
					return false;	
				}
				else 
					{
						_boolForm = 1; 
					}
					
				
				if(_boolForm == 1)
				{
			document.getElementById("frmOrders").submit();
			
			}
					
	
			else
			return false;
				
}



function numbersonly(e) {
var unicode=e.charCode? e.charCode : e.keyCode;
//alert(unicode)
	if (unicode!=8){ //if the key isn't the backspace key (which we should allow)
			if(unicode == 40 || unicode == 41) // () allowing
			{
				return true;
			}
			else if(unicode == 45 || unicode == 43) //45- && 43 + 
			{
				return true;
			}
			else if(unicode == 58 || unicode == 32) //58 :- && 32 space
			{
				return true;
			}
			else if(unicode == 37 || unicode == 39) //Delete
			{
				return true;
			}
			else if(unicode == 46 || unicode == 13) //Delete and enter
			{
				return true;
			}
			else if(unicode == 9) //tab
			{
				return true;
			}
			else if (unicode<48||unicode>57)
			{
			  document.getElementById("status").innerHTML	= "Please enter the numbers";
			  return false;//if not a number return false //disable key press
			}
		}
} 

// append image
function show_image() {
    var img = document.createElement("IMG");
    img.src = "Small Alert Icon.png";
	document.getElementById('status').appendChild(img);
}



